<!doctype html>
<html lang="ru" class="no-js">
	<head>
		<meta charset="utf-8">
		<meta name="language" content="ru" />
		<meta name="robots" content="index, follow" />
	
		<title>Журнал регистрации заявлений за {{ date.year }} год</title>
		
		<link rel="stylesheet" type="text/css" href="/static/style.css" />
		<link rel="stylesheet" type="text/css" href="/static/okno/journal.css" />
		<link rel="stylesheet" type="text/css" media="screen" href="/static/okno/view_journal.css" />
		
		<link rel="shortcut icon" href="/static/favicon.png" />
		
		<script type="text/javascript" src="/static/js/jquery-1.6.2.min.js"></script>
</head>

{% load fio %}{% load mnt %}
{% load datepicker_init datepicker %}



<body>
{% datepicker_init %}
<script>
	var dp_init = {
		flat: false,
		date: '{{ date|date:"Y-m-d" }}',
		current: '{{ date|date:"Y-m-d" }}',
		format: 'Y/m/d',
		view: 'moths',
		position: 'left',
		onChange: function(date) {
			document.location='/okno/journal/'+date;
			return true;
		},
	};
</script>
{% datepicker date_filter dp_init %}

<header>
	<h1>Журнал регистрации заявлений за {{ date.year }} год</h1>
	<div class="buttons">
		<a class="home left" href="/okno/journal/{{ date.year }}/" title="Весь журнал">&nbsp;</a>
		<a class="print" href="/okno/journal/{{ date.year}}/print/" title="Распечатать журнал за {{ date.year }} год">&nbsp;</a>
	</div>
</header>

<div class="list">
	<table width="100%" border="0" cellpadding="1" cellspacing="0">
		<thead>
		<tr>
			<th>№</th>
			<th  id="date_filter" title="Щелкните, чтобы открыть календарь">Дата</th>
			<th>ФИО заявителя</th>
			<th>ФИО сотрудника</th>
		</tr>
		</thead>
		<tfoot>
			<tr>
				<td class="pagination" colspan="4">
					{% if page.number != 1 %}
				    	<a href="/okno/journal/{{ date.year }}/1/" title="В начало">&bull;</a>
				    {% endif %}
				        
					{% if page.has_previous %}
				    	<a href="/okno/journal/{{ date.year }}/{{ page.previous_page_number }}/" title="Назад">&larr;</a>
				    {% endif %}
				
				    <span class="current">
				        Страница {{ page.number }} из {{ page.paginator.num_pages }}.
				    </span>
				
				    {% if page.has_next %}
				    	<a href="/okno/journal/{{ date.year }}/{{ page.next_page_number }}/" title="Вперед">&rarr;</a>
				    {% endif %}
				    {% if page.number != page.paginator.num_pages %}
				    	<a href="/okno/journal/{{ date.year }}/{{ page.paginator.num_pages }}/" title="В конец">&bull;</a>
				    {% endif %}
				    
				</td>
			</tr>
		</tfoot>
		<tbody>
		{% for st in page.object_list %}
		<tr>
			<td align="center">
				<a href="/okno/view/{{ st.id }}/" target="_blank" title="Просмотреть заявление">
					{{ st.number }}
				</a>
			</td>
			<td>{{ st.date }}</td>
			<td>{{ st|fio }}</td>
			<td>{{ st.user.last_name }} {{ st.user.first_name }}</td>
		</tr>
		{% endfor %}
		</tbody>
	</table>
</div>
</body>
</html>